<!DOCTYPE html>
<html lang="zh-cn">
<#include "../include/resource-head.ftl"/>
<link rel="stylesheet" href="/themes/plugins/etalage/css/etalage.css">
<body>
<#include "../include/common-header.ftl"/>
<div class="container col-center-block">
    <div class="goods-info">
        <div class="col-sm-4">
            <ul id="example" class="goods-etalage">
            <#if goodsImgList??>
                <#list goodsImgList as item>
                    <li>
                        <img class="etalage_thumb_image" src="/data/${item.path}"/>
                        <img class="etalage_source_image" src="/data/${item.path}"/>
                    </li>
                </#list>
            </#if>
            </ul>
        </div>
        <div class="goods-info-detail clearfix">
            <div class="">
                <h4>
                    <strong>${goods.name}</strong>
                </h4>
                <p class="color-grey">${goods.descript!}</p>
            </div>
            <div class="goods-business">
                <h4><i class="icon icon-bullhorn">&nbsp;</i>店铺信息</h4>
                <span>店铺：${web_name!}</span>
                <span>联系电话：${web_mobile!}</span>
            </div>
            <div class="goods-buy">
                <h4>价格:<strong class="text-red">￥${goods.price?string("#0.00")}</strong></h4>
                <form action="/order/start" method="post">
                    <input name="goodsId" value="${goods.id}" type="hidden">
                    <div class="input-group">
                        <span class="input-group-addon">数量</span>
                        <input type="text" id="num" name="num" class="form-control" style="width: 170px" placeholder="数量" value="1">
                    </div>
                    <input class="btn" value="去定制" type="submit" style="margin-top: 8px; padding: 8px 90px;background-color: #F52B00; color: #FFF;;">
                </form>
            </div>
        </div>
    </div>
    <div class="goods-detail">
        <div class="goods-box">
            <h3>店铺须知</h3>
            <div class="box-content">${web_notice!}</div>
        </div>
        <div class="goods-box">
            <h3>礼品介绍</h3>
            <div class="box-content">${goods.content!}</div>
        </div>
        <div class="goods-box">
            <h3>用户评价</h3>
            <div class="box-content">
            <#if pageInfo.list?? && pageInfo.list?size gt 0>
                <#list pageInfo.list as item>
                    <div class="item">
                        <h4 class="">${item.username}</h4>
                        <span class="color-grey" style="font-style: italic">${item.addtime?string('yyyy-MM-dd HH:mm:ss')}</span>
                        <p>${item.content!}</p>
                    </div>
                </#list>
                <#else>
                <div class="text-center">
                    <h2>暂无评论</h2>
                </div>
            </#if>
            </div>
        </div>
    </div>
</div>
<#include "../include/common-foot.ftl"/>
</body>
<#include "../include/resource-script.ftl"/>
<script src="/themes/plugins/etalage/js/jquery.etalage.min.js"></script>
<script>
    $(document).ready(function ($) {
        $('#example').etalage({
            thumb_image_width: 320,//缩略图的宽度
            thumb_image_height: 350,//缩略图的高度
            source_image_width: 900,//大图的宽度
            source_image_height: 1200,//大图的高度
            autoplay: true //自动轮播
        });
    })

    $("#num").onlyNum();
</script>
</html>